/*
 * @Author: yangrongxin
 * @Date: 2021-05-14 09:10:59
 * @LastEditors: yangrongxin
 * @LastEditTime: 2021-05-18 16:52:23
 */
import React from 'react';
import { View, Text, Image, Button } from '@tarojs/components';
import { AtModal, AtModalContent, AtIcon, AtModalAction } from 'taro-ui';
import styles from './index.module.less';

const ComingSoon = (props) => {
  const { isOpened, onClose, title = '该功能即将开通', subTitle = '敬请期待' } = props;

  return (
    <AtModal className={styles.modalWapper} isOpened={isOpened} closeOnClickOverlay={false}>
      <AtModalContent>
        <View className={styles.contentWapper}>
          <Image src="https://hxgywx.oss-cn-shenzhen.aliyuncs.com/nursing-customer/assets/jqqd_header.png" />
          <View>
            <Text>{title}</Text>
            <Text>{subTitle}</Text>
          </View>
          <Button onClick={onClose}>知道了</Button>
        </View>
      </AtModalContent>
      <AtModalAction>
        <View className={styles.closeIcon} onClick={onClose}>
          <AtIcon prefixClass="icon" value="times-circle-fill" />
        </View>
      </AtModalAction>
    </AtModal>
  );
};

export default ComingSoon;
